package com.michael.study.library.base;

/**
 * Description:
 *
 * <p>Created by liuguoquan on 2020/8/5 20:42.
 */
public class AppInfo {

    private static volatile AppInfo sInstance = null;
    private boolean isDebug = false;

    private AppInfo() {}

    public static AppInfo getInstance() {
        if (sInstance == null) {
            synchronized (AppInfo.class) {
                if (sInstance == null) {
                    sInstance = new AppInfo();
                }
            }
        }

        return sInstance;
    }

    public synchronized String getToken() {
        return "daldhahd";
    }

    public synchronized String getUserId() {
        return "123";
    }

    public void init(boolean debug) {
        isDebug = debug;
    }

    public boolean isDebug() {
        return isDebug;
    }
}
